/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package util;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

/**
 *
 * @author ThanhTai
 */
public class DBUtil {

    private Properties prop = new Properties();//

    public DBUtil() {
        try {
            InputStream is = DBUtil.class.getResourceAsStream("/Connection/ConnectionInfo.properties");
            prop.load(is);
            is.close();
        } catch (IOException e) {
            return;
        }
    }

    public String getDriverName() {
        return prop.getProperty("driverName");
    }

    public String getURL() {
        return prop.getProperty("url");
    }

    public String getUsername() {
        return prop.getProperty("username");
    }

    public String getPassword() {
        return prop.getProperty("password");
    }
}
